﻿<controls:ChildWindow xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk"  x:Class="VAdvantage.Framework.Editor"
           xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
           xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
           xmlns:controls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls"
           Width="330" Height="392" 
           Title="Editor">
    <Grid x:Name="LayoutRoot" Margin="2">
        <Grid.RowDefinitions>
            <RowDefinition Height="*" />
                <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>

        <Button x:Name="CancelButton" Visibility="Collapsed"  Click="CancelButton_Click" Width="35" Height="35" HorizontalAlignment="Right" Margin="0,0,37,0" Grid.Row="1" >
            <Image Source="/VAdvantage;component/Images/cancel_up.png" Stretch="Fill"></Image>
        </Button>
        
        <Button x:Name="OKButton" Click="OKButton_Click" Width="35" Height="35" Margin="0,0,0,0" HorizontalAlignment="Right"   Grid.Row="1" >
            <Image Source="/VAdvantage;component/Images/right_up.png" Stretch="Fill"></Image>
        </Button>
        
        <controls:TabControl  HorizontalAlignment="Stretch" Grid.Row="0" Name="tabControl1" VerticalAlignment="Stretch" SelectionChanged="tabControl1_SelectionChanged">
            <controls:TabItem Header="Text" Name="tbText">
                <Grid >
                    <TextBox TextWrapping="Wrap" Name="rtxtTextTab" KeyDown="rtxtTextTab_KeyDown" KeyUp="rtxtTextTab_KeyUp"></TextBox>
                </Grid>
            </controls:TabItem>
            <controls:TabItem Header="HTML" Name="tbHtml">
                <Grid >
                    <WebBrowser Name="browser" />
                </Grid>
            </controls:TabItem>
        </controls:TabControl>
       
        <StackPanel Grid.Row="2" HorizontalAlignment="Stretch" Orientation="Horizontal">
            <Grid HorizontalAlignment="Stretch" Width="307">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="*"></ColumnDefinition>
                    <ColumnDefinition Width="Auto"></ColumnDefinition>
                </Grid.ColumnDefinitions>
                <StackPanel Grid.Column="0" Orientation="Horizontal" HorizontalAlignment="Stretch">
                    <TextBlock  Name="lblCurrentText" VerticalAlignment="Center"  TextAlignment="Center" HorizontalAlignment="Right" />
                    <TextBlock Margin="4" Name="lblOprator" Text=">" VerticalAlignment="Center"  TextAlignment="Center" HorizontalAlignment="Right" />
                    <TextBlock Name="lblTotal" VerticalAlignment="Center"  TextAlignment="Center" HorizontalAlignment="Right" />
                </StackPanel>
                <TextBlock Name="lblNoOfText" Text="0" VerticalAlignment="Center"  TextAlignment="Center"  Grid.Column="1"  HorizontalAlignment="Right" />
            </Grid>
        </StackPanel>
    </Grid>
</controls:ChildWindow>